<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/common.jsp"%>
<div class="pageContent">
	<form action="${ctxPath }/drp/drpProduct/edit" 
		class="pageForm required-validate" 
        onsubmit="return validateCallback(this, dialogAjaxDone);" method="post" >
        <input type="hidden" name="navTabId" value="ghsgl">
        <input type="hidden" name="callbackType" value="closeCurrent">
        <input type="hidden" name="forwardUrl" value="">
        
        <input type="hidden" name="id" value="${entity.id }">
        
        <div class="pageFormContent"  layoutH="56">
        	<p>
				<label>名称：</label>
				<input type="text" name="name" class="required"  maxlength="10" size="25" value="${entity.name }"/>
			</p>
			<p>
				<label>图片：</label>
				<img src="${ctxPath }/${entity.img }" width="100" height="100"/>
				<input type="file" name="file" size="25" />
			</p>
			<p>
				<label>采购价：</label>
				<input type="text" name="purchasePrice" class="number"  maxlength="16" size="25" value="${entity.purchasePrice }"/>
			</p>
			<p>
				<label>售价：</label>
				<input type="text" name="salePrice" class="number"  maxlength="16" size="25" value="${entity.salePrice }"/>
			</p>
			<p>
				<label>优惠价：</label>
				<input type="text" name="preferentialPrice" class="number" value="0"  maxlength="16" size="25" value="${entity.preferentialPrice }"/>
			</p>
			<p>
				<label>商品类型：</label>
				<input id="productType" name="productType.id" value="${entity.productType }" type="hidden"/>
				<input class="required" name="productType.name" type="text" value="${entity.productTypeName }"
					postField="keyword" suggestFields="name" lookupGroup="productType"
					suggestUrl="${ctxPath }/drp/drpProductType/selectList" />
			</p>
			<p>
				<label>所属供货商：</label>
				<input id="supplier" name="supplier.id" value="${entity.supplierId }" type="hidden"/>
				<input  name="supplier.name" type="text" value="${entity.supplierName }"
					postField="keyword" suggestFields="name" lookupGroup="supplier"
					suggestUrl="${ctxPath }/drp/drpSupplier/selectList" />
			</p>
			<p>
				<label>型号：</label>
				<input type="text" name="models"  maxlength="250" size="25" value="${entity.models }"/>
			</p>
			<p>
				<label>材质：</label>
				<input type="text" name="texture" maxlength="250" size="25" value="${entity.texture }"/>
			</p>
			<p>
				<label>功能：</label>
				<input type="text" name="effect" maxlength="250" size="25" value="${entity.effect }"/>
			</p>
			<p>
				<label>是否上架：</label>
				<select name="upStatus" id="combox_upStatus">
					<option value="0" <c:if test="${entity.upStatus == 0 }">selected="selected"</c:if> >未上架</option>
					<option value="1" <c:if test="${entity.upStatus == 1 }">selected="selected"</c:if> >已上架</option>
				</select>
			</p>
			<p style="height: 50px;">
				<label>备注：</label>
				<textarea rows="5" cols="27" name="remark" >${entity.remark }</textarea>
			</p>
		</div>
		<div class="formBar">
			<ul>
				<li>
					<div class="buttonActive">
						<div class="buttonContent">
							<button type="submit">保存</button>
						</div>
					</div>
				</li>
				<li>
					<div class="button">
						<div class="buttonContent">
							<button type="button" class="close">取消</button>
						</div>
					</div>
				</li>
			</ul>
		</div>
	</form>
</div>